home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2007 September / PCWSEP07.iso / Software / Linux / Linux Mint 3.0 Light / LinuxMint-3.0-Light.iso / casper / filesystem.squashfs / etc / menu-methods / gnome-panel-data next >
Encoding:
Text File  |  2006-10-17  |  1.2 KB  |  53 lines

  1. #!/usr/bin/install-menu
  2. compat="menu-1"
  3.  
  4. !include menu.h
  5.  
  6. function findicon($filename)= \
  7.     ifelsefile($filename, $filename, \
  8.     iffile("/usr/X11R6/include/X11/pixmaps/" $filename, \
  9.     "/usr/X11R6/include/X11/pixmaps/" $filename))
  10.  
  11. function AppEntry($var)= \
  12.     "[Desktop Entry]\n" \
  13.     "Encoding=UTF-8\n" \
  14.     "Name=" title() "\n" \
  15.     "Comment=" ifelse($longtitle,$longtitle,"") "\n" \
  16.     "Exec=" $command "\n" \
  17.     $var  \
  18.     ifnempty($icon,"Icon=" findicon($icon) "\n") \
  19.     "Type=Application\n" 
  20.  
  21. # To add a default icon if no icon are provided (ugly)
  22. #    ifelse($icon,"Icon="findicon($icon) "\n","Icon=gnome-debian.png\n") \
  23.  
  24. function SubmenuEntry()= \
  25.     "[Desktop Entry]\n" \
  26.     "Name=" $title "\n" \
  27.     "Icon=gnome-fs-directory\n" \
  28.     "Type=Directory\n"
  29.  
  30. supported
  31.   x11=  AppEntry("Terminal=false\n")
  32.   text= AppEntry("Terminal=true\n")
  33. endsupported
  34.  
  35. genmenu=ifeqelse(parent($title),"",parent($section),parent(parent($section))) "/" replacewith($title,"/","_") ifeqelse($needs, "", "/.directory", ".desktop") ""
  36. startmenu=""
  37. endmenu=""
  38.  
  39. rootsection=""
  40.  
  41. rootprefix="/var/lib/gnome/Debian/"
  42. userprefix=".gnome/apps"
  43.  
  44. treewalk="M"
  45. submenutitle=SubmenuEntry()
  46.  
  47. prerun="rm -rf " prefix() "/*"
  48.  
  49. preoutput=""
  50.  
  51. outputencoding="UTF-8"
  52.  
  53.